import execjs

#在python中执行js
print(execjs.get())

js_code = ("""
function run_func(a,b){
    return a + b
}


""")

run_js = execjs.compile(js_code)
print(run_js.call('run_func',1,2))